﻿<%@ Page Title="" Language="VB" MasterPageFile="~/Prototype.master" AutoEventWireup="false" CodeFile="ListDiscussions.aspx.vb" Inherits="Discussions_ListDiscussions" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<fieldset>
<legend><label for="Title">Discussion LiSTS</label></legend>
    <asp:GridView ID="DG" runat="server" AutoGenerateColumns="False" 
        DataKeyNames="ID" DataSourceID="DSDiscussions">
        <Columns>
            <asp:BoundField DataField="ID" HeaderText="ID" InsertVisible="False" 
                ReadOnly="True" SortExpression="ID" />
            <asp:BoundField DataField="Topic" HeaderText="Topic" SortExpression="Topic" />
            <asp:BoundField DataField="Author" HeaderText="Author" 
                SortExpression="Author" />
            <asp:HyperLinkField DataNavigateUrlFields="ID" 
                DataNavigateUrlFormatString="DiscussionDetails.aspx?ID={0}" 
                HeaderText="Discussion" Text="Enter Discussions" />
        </Columns>
    </asp:GridView>
    <asp:SqlDataSource ID="DSDiscussions" runat="server" 
        ConnectionString="<%$ ConnectionStrings:myFirstDatabase %>" 
        ProviderName="<%$ ConnectionStrings:myFirstDatabase.ProviderName %>" 
        SelectCommand="SELECT [ID], [Topic], [Author], [Category] FROM [tblDiscussions]"></asp:SqlDataSource>
        </fieldset>
</asp:Content>

